class ControlManager
{
    private ctrlList = {};

    Init()
    {
        this.ctrlList[CtrlNames.Warehouse] = new WarehouseController();
        this.ctrlList[CtrlNames.Field] = new FieldController();
        this.ctrlList[CtrlNames.Player] = new PlayerController();
        this.ctrlList[CtrlNames.Task] = new TaskController();
        this.ctrlList[CtrlNames.Darw] = new DarwController();
        this.ctrlList[CtrlNames.Mail] = new MailController();
        this.ctrlList[CtrlNames.Sign] = new SignController();
        this.ctrlList[CtrlNames.Rank] = new RankController();
        this.ctrlList[CtrlNames.Friend] = new FriendController();
        this.ctrlList[CtrlNames.Share] = new ShareController();
        this.ctrlList[CtrlNames.Shield] = new ShieldController();
    }

    //获取Ctrl
    GetCtrl(ctrlName : string) : any 
    {
        return this.ctrlList[ctrlName];
    }
}
let CtrlManager : ControlManager = new ControlManager();